package com.myspringmvc.controller;

import com.myspringmvc.annotation.RequestMapping;
import com.myspringmvc.annotation.bean.Controller;
import com.mytomcat.servlet.MyHttpServletRequest;
import com.mytomcat.servlet.MyHttpServletResponse;

/**
 * 内置404页面
 */
@Controller
public class _404Controller {

    @RequestMapping("/404")
    public void _404(MyHttpServletRequest request, MyHttpServletResponse response) throws Exception {
        response.returnHtmlResponse(404,
                "<h1 style='color: red'>404 Not Found</h1> <br>request: " + request);
    }
}
